#encoding=utf-8
import os

File_Path = os.getcwd()
print File_Path
File_Path = File_Path + "/test"
if not os.path.exists(File_Path):
    print File_Path
    os.makedirs(File_Path)
text_path = File_Path + "/test.txt"
text = open(text_path,"w+")

print "文件名：",text.name
text.write("这是测试文件")

text.close()